package cn.janus.component.claims;

import io.jsonwebtoken.Claims;
import io.jsonwebtoken.impl.DefaultClaims;

import java.io.Serializable;
import java.util.Set;

public final class CustomClaims extends DefaultClaims implements Serializable {
    private Set<String> roles;

    public Set<String> getRoles() {
        Set<String> o = (Set<String>) this.get(roles);
        return o;

    }

    public Claims setRoles(Set<String> roles) {
        this.setValue("roles", roles);
        return this;
    }

    public static CustomClaims builder() {
        return new CustomClaims();
    }
}
